<template>
	<view class="retrieved">
		<view class="topBack">
			<image class="topImg"
				src="https://chongwu.aitaoba.net/storage/uploads/20231118/ccfe2146361dd0057614f4f90757bad3.png"></image>
			<text class="topText">恭喜宠主！</text>
			<view class="topCenter">
				恭喜宠主<text class="colorFontClass">寻回您的爱宠</text>，请照看
				好小宝贝，避免再次丢失
			</view>
			<button class="confirmClass" @tap="goPetDetails">确认</button>
		</view>
	</view>
</template>

<script>
	export default {
		components: {

		},
		data() {
			return {
				itemData: {},

			};
		},

		/**
		 * 跳转到个人中心
		 */
		onBackPress(e) {

		},
		onPullDownRefresh() {

		},
		onShow() {

		},

		onLoad(options) {

			this.itemData = JSON.parse(decodeURIComponent(options.item));
			console.log(this.itemData, 'yayyayayayyay')
		},


		watch: {

		},
		methods: {
			goPetDetails() {
				// getApp().globalData.isRetrieved=true;
				// uni.navigateTo({
				// 	url: "/pages/petDetails/petDetails?item" + encodeURIComponent(JSON.stringify(this.itemData))
				// })
				uni.switchTab({
					url: '/pages/pet/pet'
				})
			},
		},
	};
</script>

<style lang="scss" scoped>
	.topBack {
		width: 750rpx;
		height: 257rpx;
		background: linear-gradient(180deg, #FAE24E 0%, rgba(250, 226, 78, 0) 100%);
		display: flex;
		flex-direction: column;

		align-items: center;
		padding-top: 46rpx;
		box-sizing: border-box;
	}

	.topImg {
		width: 416rpx;
		min-height: 380rpx;

	}

	.topText {
		font-size: 44rpx;
		font-family: PingFang SC-Heavy, PingFang SC;
		font-weight: 800;
		color: #2E2908;
		margin-top: 43rpx;
	}

	.topCenter {
		width: 420rpx;
		// height: 82rpx;
		text-align: center;

		margin-top: 38rpx;
	}

	.colorFontClass {
		color: #FC7A2E;
	}

	.confirmClass {
		width: 360rpx;
		min-height: 88rpx !important;
		background: #FED24C;
		border-radius: 20rpx;

		border: 2rpx solid #683518;
		outline: none;
		font-size: 32rpx;
		font-family: PingFang SC-Heavy, PingFang SC;
		font-weight: 800;
		color: #683518;
		text-align: center;
		line-height: 88rpx !important;
		margin-top: 104rpx;
	}
</style>